<template>
    <div>
        <div class="collect_main" v-if="collectList">
			<div v-for="item in collectList" class="collect_box">
				<el-popover placement="top" width="160" v-model="item.visible" trigger="click">
					<p>确定删除吗？</p >
				    <div style="text-align: right; margin: 0">
				        <el-button type="primary" size="mini" @click="delCollect(item.product_id)">确定</el-button>
				   	</div>
					<span slot="reference" @click="item.visible = true" class="sp_del">×</span>
              <my-list :listData="collecList" :ismore="true"></my-list>

				</el-popover>
    </div>
</template>
<script>
import API from '../api/collect'
export default {
    data() {
        return {
            collecList:[]
        }
    },
     created() {
        this.getCollect()
    },
    methods: {
        async getCollect(){
            let res=await API.collectList({"user_id":this.$store.state.user_id})
            this.collecList=res.collectList
         }
    },
}
</script>
<style lang="scss" scoped>
    
</style>